﻿<Window x:Class="TravelAgencyWpfPictureAdder.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="MainWindow" Height="450" Width="925">
    <Grid>
        <StackPanel Orientation="Horizontal">
            <StackPanel Width="300">
                <Button x:Name="buttonLoadPicture" Content="Load Picture" Click="buttonLoadPicture_Click" />
                <TextBlock x:Name="textBlockImageFileName" />
                <TextBox x:Name="textBoxImageNameInDatabase" Text="Photo Name" />
                <Button x:Name="buttonAddImage" Content="Add Image To DB" Click="buttonAddImage_Click" />
                <Image x:Name="imageToAdd" MaxWidth="300" MaxHeight="300" />
            </StackPanel>
            <StackPanel>
                <ScrollViewer Width="300" Height="300">
                    <DataGrid x:Name="dataGridPhotos"                   
                              ItemsSource="{Binding Photos}"
                              SelectionChanged="dataGridPhotos_SelectionChanged"/>
                </ScrollViewer>
            </StackPanel>
            <Image x:Name="imageFromDataGrid" MaxWidth="300" MaxHeight="300"/>
        </StackPanel>
    </Grid>
</Window>
